package com.example.demo.repository;


import com.example.demo.model.Restaurant;
import org.springframework.stereotype.Repository;

import java.util.Arrays;
import java.util.List;

@Repository
public class RestaurantRepository {

    // 模拟从数据库中获取数据
    public List<Restaurant> findAll() {
        return Arrays.asList(
                new Restaurant("惊喜餐厅", "市中心", "特色美食"),
                new Restaurant("家常餐馆", "郊区", "家常菜"),
                new Restaurant("豪华餐厅", "商业区", "西餐")
        );
    }

}

